package apache.openejb.session.bean.stateless;

import java.net.InetAddress;
import java.net.UnknownHostException;

import javax.ejb.Stateless;

@Stateless
public class HelloWorldImpl implements HelloWorldLocal, HelloWorldRemote {
    
    public String sayHello(String message) {
        String hostname = null;
        try {
            hostname = InetAddress.getLocalHost().getHostName();
        } catch (UnknownHostException e) {
            e.printStackTrace();
        }

        return message + " via session bean sayHello() Impl at " + hostname;
    }
}
